#include "Sum.h"

extern int num;
extern int loop;
extern CRITICAL_SECTION criticalSection;
void Sum::Run()
{
	for (int i =0; i < loop; i++)
	{
		EnterCriticalSection(&criticalSection);
		num++;
		LeaveCriticalSection(&criticalSection);
	}
}